import request from './request';

//上传
export const upData = (data:object) => {
    return request({
        url: '/api/upload/image',
        method: 'post',
        data,
    });
}
export const poster = (data:object) => {
    return request({
        url: '/api/poster/index',
        method: 'get',
        params: data
    });
}

export const posterUser = (data:object) => {
    return request({
        url: '/api/poster/user',
        method: 'get',
        params: data
    });
}

export const downloadImage = (data:object) => {
    return request({
        url: data.url,
        method: 'get',
        // params: data
    });
}

//年度回顾
export const reviewUser = (data:object) => {
    return request({
        url: '/api/review/user',
        method: 'post',
        data
    });
}
//获取地区
export const reviewProvince = (data:object) => {
    return request({
        url: '/api/review/province',
        method: 'get',
        params:data
    });
}
//授权协议
export const articleDetail = (data:object) => {
    return request({
        url: '/api/article/detail',
        method: 'get',
        params:data
    });
}

//奖品数量
export const querynum = (data:object) => {
    return request({
        url: '/api/vivo.coupon/querynum',
        method: 'get',
        params:data
    });
}
//抽奖
export const draw = (data:object) => {
    return request({
        url: '/api/vivo.coupon/draw',
        method: 'get',
        params:data
    });
}

//抽奖记录
export const logs = (data:object) => {
    return request({
        url: '/api/vivo.coupon/logs',
        method: 'get',
        params:data
    });
}
//验证码
export const reviewCode = (data:object) => {
    return request({
        url: `/api/review/code3/mobile/${data.mobile}`,
        method: 'get',
    });
}